const Usecase = require('../../shared/usecase/Usecase')

class GetUserDetail extends Usecase {
  constructor({ userRepo }) {
    super()
    this.userRepo = userRepo
  }
  async execute(id) {
    const data = await this.userRepo.findById(id, {
      include: ['roleList'],
    })
    return data
  }
}

module.exports = GetUserDetail
